const state = {
    userInfo: {},
    token: '',
    num: ''
}

const getters = {
    userInfo: _state => _state.userInfo,
    token: _state => _state.token,
    num: _state => _state.num
}

const mutations = {
    setUserInfo(_state, _userInfo) {
        _state.userInfo = _userInfo
    },
    setToken(_state, _token) {
        _state.token = _token
    }, 
    setNum(_state, _num){
        _state.num = _num
    }
}

const common = {
    state,
    getters,
    mutations,
    namespaced: true
}

export default common